package com.franklin.ideaplugin.easytesting.entity;

import com.franklin.ideaplugin.easytesting.common.entity.ETRsp;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;

import java.util.LinkedHashMap;
import java.util.Map;

/**
 * @author Ye Junhui
 * @since 2023/6/21 22:53
 */
@Data
@AllArgsConstructor
@NoArgsConstructor
public class ExecuteResult {

    private LinkedHashMap<String,Object> paramMap;

    private ETRsp<?> etRsp;

    private Long executeTime;

    private boolean success;

    private String cachePath = "";

    public void setEtRsp(ETRsp<?> etRsp) {
        this.etRsp = etRsp;
        this.success = etRsp.getCode().equals("200");
    }
}
